package com.fqgj.sentry.controller.mc;

import com.fqgj.sentry.biz.mc.MenuBusiness;
import com.fqgj.sentry.biz.mc.vo.menu.ShowMenuVo;
import com.fqgj.sentry.common.cache.RequestLocalInfo;
import com.fqgj.sentry.common.response.ApiOutput;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by ykpbean kangping.ying@yuntu-inc.com
 *
 * @description
 * @create 2017-07-20 下午3:02
 */

@RestController
@RequestMapping("/menu")
public class MenuController {
    @Autowired
    private MenuBusiness menuBusiness;

    @RequestMapping(value = "/show", method = RequestMethod.POST)
    public ApiOutput getShowMenu() {
        ShowMenuVo showMenuVo = menuBusiness.getMenuList(RequestLocalInfo.getCurrentUserId(), RequestLocalInfo.getCurrentMerchantId());
        return new ApiOutput<>(showMenuVo);
    }


}
